if (trackpoint->altitude != unknown_alt && trackpoint->altitude != 0) {
coords.append(trackpoint->altitude);
}
- (*track_coords).append(coords);
+ track_coords->append(coords);
}
void GeoJsonFormat::geojson_track_tlr(const route_head* /*unused*/)
Waypoint* waypoint = new Waypoint();
waypoint->latitude = lat_e7 / 1e7;
waypoint->longitude = lon_e7 / 1e7;
- if (shortname && (*shortname).length() > 0) {
+ if (shortname && shortname->length() > 0) {
waypoint->shortname = *shortname;
}
- if (description && (*description).length() > 0) {
+ if (description && description->length() > 0) {
waypoint->description = *description;
}
- if (start_str && (*start_str).length() > 0) {
+ if (start_str && start_str->length() > 0) {
gpsbabel::DateTime start = QDateTime::fromString(*start_str, Qt::ISODate);
waypoint->SetCreationTime(start);
}
const char* m1;
const char* m2;
bool isDLE = false;
- p = (*packet).data;
+ p = packet->data;
start = GPS_Time_Now();
GPS_Diag("Rx Data:");
}
if (len == 1) {
- (*packet).type = u;
+ packet->type = u;
++len;
continue;
}
}
if (len == 2) {
- (*packet).n = u;
+ packet->n = u;
len = -1;
continue;
}
if (u == ETX)
if (isDLE) {
- if (p - (*packet).data - 2 != (*packet).n) {
+ if (p - packet->data - 2 != packet->n) {
GPS_Error("GPS_Packet_Read: Bad count");
gps_errno = FRAMING_ERROR;
return 0;
chk_read = *(p - 2);
unsigned int i;
- for (i = 0, p = (*packet).data; i < (*packet).n; ++i) {
+ for (i = 0, p = packet->data; i < packet->n; ++i) {
chk -= *p++;
}
chk -= packet->type;
return 0;
}
- m1 = Get_Pkt_Type((*packet).type, (*packet).data[0], &m2);
+ m1 = Get_Pkt_Type(packet->type, packet->data[0], &m2);
if (gps_show_bytes) {
GPS_Diag(" ");
for (unsigned j = 0; j < packet->n; j++) {
- char c = (*packet).data[j];
+ char c = packet->data[j];
GPS_Diag("%c", isascii(c) && isalnum(c) ? c : '.');
}
GPS_Diag(" ");
}
GPS_Diag("(%-8s%s)\n", m1, m2 ? m2 : "");
- return (*packet).n;
+ return packet->n;
}
if (p - packet->data >= MAX_GPS_PACKET_SIZE) {
return false;
}
- if (LINK_ID[0].Pid_Ack_Byte != (*rec).type) {
+ if (LINK_ID[0].Pid_Ack_Byte != rec->type) {
gps_error = FRAMING_ERROR;
/* rjl return 0; */
}
- if (*(*rec).data != (*tra).type) {
+ if (*rec->data != tra->type) {
gps_error = FRAMING_ERROR;
return false;
}